package com.tsing.common.utils;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

public class ListUtil {

    private final static Logger logger = LoggerFactory.getLogger(ListUtil.class);

    @SuppressWarnings({"rawtypes", "unchecked"})
    public static List<String> getDifference(List<String> res, List<String> compare) {
        List<String> result = new ArrayList<String>();
        Collection exists = new ArrayList<String>(res);
        exists.removeAll(compare);
        result.addAll(exists);
        return result;
    }

}
